package task9;

import java.util.Scanner;

/**
 * @author banana
 * 任意输入一个整数，求它的位数！
 */
public class Test1 {
    public static void main(String[] args) {
        System.out.println("请输入一个数!");
        Scanner scanner=new Scanner(System.in);
        int num=scanner.nextInt();
        int count=0;
        while(num>0){
            num=num/10;
            count++;
        }
        System.out.println("位数"+count);
    }
}
